Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add support for ipv6 hostnames to the constructor string parser. (Fix… #114

Merged
merged 1 commit into from
Sep 1, 2021

Conversation

wanderview
Copy link
Member

@wanderview wanderview commented Sep 1, 2021

…es #113)


Preview | Diff

@wanderview
Copy link
Member Author

@domenic PTAL. This pretty much matches what the URL parser does to ignore colons while inside [ ] brackets:

https://url.spec.whatwg.org/#hostname-state

Copy link
Member

@domenic domenic left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pretty simple!

@wanderview wanderview merged commit 8faa51b into main Sep 1, 2021
@wanderview wanderview deleted the dev-ipv6 branch September 1, 2021 23:18
@wanderview
Copy link
Member Author

Actually, I wonder if the encoding callback to use the host parser in the url spec will be too restrictive. Like, if it sees a partial pattern string '[::' will it throw because there is no enclosing bracket? I'll check tomorrow.

crowlKats added a commit to crowlKats/rust-urlpattern that referenced this pull request Sep 2, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

2 participants